home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1996 March / EnigmA AMIGA RUN 05 (1996)(G.R. Edizioni)(IT)[!][issue 1996-03][Skylink CD IV].iso / earcd / program / amcfp140.lha / AMCAF_Examples / Fonts.AMOS / Fonts.amosSourceCode < prev   
AMOS Source Code  |  1996-01-19  |  2KB  |  57 lines

  1. ' ************************************* Commands used: 
  2. ' *                                   * Change Bank Font   Flush Libs  
  3. ' *           Amcaf Examples          * Change Print Font
  4. ' *             Fonts V1.1            * Change Font
  5. ' *      Written by Chris Hodges      * Make Bank Font 
  6. ' *                                   * Imploder Unpack
  7. ' ************************************* Bank Temporary 
  8. '
  9. ' First, decrunch the FileImploded FontBank into chip ram. 
  10.  Extension_8_0E8A 9 To -8
  11. ' Open a neat little screen for our text.
  12. Screen Open 0,320,256,4,Lowres
  13. Curs Off : Flash Off : Paper 0 : Pen 1 : Cls 0
  14. Palette 0,$FFF,$8F8,$88F
  15. ' Change the font to Iva 50. 
  16.  Extension_8_1204 8
  17. ' Print some nice text onto the screen.
  18. Ink 1,0 : Text 0,Text Base,"Hello World!"
  19. ' Set a new print font. This font is saved in bank 10. 
  20.  Extension_8_11A0 10
  21. ' Now print out some text. 
  22. Locate 0,8 : Pen 2
  23. Centre "What an ugly print-font, eh?" : Print 
  24. Centre "But I don't care, so why should you?" : Print : Print 
  25. Pen 3
  26. Centre "AMCAF - the next generation"
  27. ' Again, change the text font. I hope you have the diskfont.library? 
  28.  Extension_8_059C "topaz",16
  29. ' Print out an irritating line of text.
  30. Text 0,112+Text Base,"Waaahhh! Topaz 16!!!"
  31. ' Grab the font into a bank. The bank should be temporary in this case.
  32.  Extension_8_11EE 11 : Extension_8_008A 11
  33. ' Just look! 
  34. Locate 0,18
  35. List Bank 
  36. ' Wait for keypress. 
  37. Print 
  38. Centre "Press any key to proceed."
  39. Wait Key 
  40. ' Now close screen 0, to get rid of the different fonts. 
  41. Screen Close 0
  42. ' Additionally, flush everything away. 
  43.  Extension_8_05D6 
  44. ' Now reopen a fresh screen and change the font back.
  45. Screen Open 0,320,256,4,Lowres
  46. Curs Off : Flash Off : Paper 0 : Pen 1 : Cls 0
  47. Palette 0,$FFF,$8F8,$88F
  48.  Extension_8_1204 11
  49. ' The usual babble...
  50. Ink 2,0
  51. Text 0,Text Base+100,"Sometimes the"
  52. Text 0,Text Base+132,"fonts come back!"
  53. ' Quit the program after the user has pressed a key. 
  54. Locate 0,23 : Centre "Press any key to quit."
  55. Wait Key 
  56. Screen Close 0
  57. End